import {nodeResolve} from "@rollup/plugin-node-resolve";
import PluginVue from "rollup-plugin-vue";
import replace from "@rollup/plugin-replace";
import commonjs from "@rollup/plugin-commonjs";

export let sw;
sw = {
  input: 'src/js/service-worker.js',
  plugins: [
    nodeResolve(),
    replace({
      'process.env.NODE_ENV': JSON.stringify(process.env.NODE_ENV),
      preventAssignment: true
    })
  ]
};


export let journal
journal = {
  input: './src/js/journal.js',
  external: ['vue'],
  plugins: [
    nodeResolve(),
    PluginVue({
      preprocessStyles: true,
    }),
    commonjs()
  ]
};
